//
// Created by 32827 on 2024/5/19.
//

#ifndef STM32F407VET6_YZL_LCD1306_H
#define STM32F407VET6_YZL_LCD1306_H
#include "yz_color.h"
#include "yzl_driver.h"
#ifdef YZL_I2C_1306_ENABLE
#include "yzl_i2c_lcd1306.h"

extern uint8_t sram_1306[];
#if YZL_I2C_SoftPort_ENABLE

//TODO

#else
#include "yz_time.h"

YZF_RESULT yzl_1306_screen_init(YZF_I2C_POINTER i2c);

YZF_RESULT yzl_1306_clear(uint16_t usX, uint16_t usY, uint16_t usWidth, uint16_t usHeight, YZ_COLOR usColor);

YZF_RESULT yzl_1306_draw_rect(uint16_t usX_Start, uint16_t usY_Start, uint16_t usWidth, uint16_t usHeight, uint8_t ucFilled, YZ_COLOR usColor);

YZF_RESULT yzl_1306_refresh(YZF_I2C_POINTER i2c);

YZF_RESULT yzl_1306_draw_pixel(uint16_t usX, uint16_t usY, YZ_COLOR usColor);

YZ_COLOR yzl_1306_read_pixel(uint16_t usX, uint16_t usY);

YZF_RESULT yzl_1306_draw_circle(uint16_t usX_Center, uint16_t usY_Center, uint16_t usRadius, uint8_t ucFilled,YZ_COLOR usColor);

YZF_RESULT yzl_1306_draw_line(uint16_t usX1, uint16_t usY1, uint16_t usX2, uint16_t usY2, YZ_COLOR usColor );
#endif
#endif
#endif //STM32F407VET6_YZL_LCD1306_H
